package cn.px.service.purchase;

import cn.px.dao.entity.purchase.PurchaseDispatchOrderList;
import cn.px.dao.entity.purchase.PurchaseOrderDispatchOrder;
import cn.px.dao.vo.query.purchase.PurchaseDispatchOrderListVO;
import cn.px.dao.dto.purchase.PurchaseDispatchOrderListDTO;
import cn.px.common.bean.AbstractPageResultBean;
import cn.px.service.base.IBaseService;

import java.util.List;

/**
 * @Description 采购发运单明细 service
 * @author 品讯科技
 * @date 2024-08
 * @Version Copyright (c) 2020,北京乾元坤和科技有限公司 All rights reserved.
 */
public interface PurchaseDispatchOrderListService extends IBaseService<PurchaseDispatchOrderList, PurchaseDispatchOrderListDTO> {

    /**
     * 批量删除
     *
     * @param ids ：
     * @return ：
     */
    int batchDelete(List<String> ids);

    /**
     * 分页查询
     *
     * @param record
     * @param pageNum
     * @param pageSize
     * @return
     */
    AbstractPageResultBean<PurchaseDispatchOrderListVO> selectPageList(PurchaseDispatchOrderListDTO record, int pageNum, int pageSize);

//    /**
//     * 添加
//     *
//     * @param order
//     * @param objects
//     */
//    void handleListByDispatchOrder(PurchaseDispatchOrder order, List<Object> objects, Integer action);

    /**
     * 更新 已到数量
     *
     * @param list
     */
    void updateArrivedQuantity(List<PurchaseDispatchOrderList> list);

    /**
     * 导入发运明细
     *
     * @param dispatchOrderId
     * @param items
     */
    void importList(String dispatchOrderId, List<PurchaseDispatchOrderList> items);

    /**
     * 添加
     *
     * @param orderId
     * @param records
     */
    void handleListByDispatchOrder(String orderId, List<PurchaseDispatchOrderListDTO> records);

    /**
     * 添加
     *
     * @param order
     * @param objects
     */
    void handleListByPurchaseOrderDispatchOrder(PurchaseOrderDispatchOrder order, List<Object> objects, Integer action);
}
